package com.suke.czx.modules.performanceconfig.entity;

import lombok.Data;

import javax.validation.constraints.Max;
import javax.validation.constraints.NotNull;
import java.math.BigDecimal;

/**
 * 应用模块名称: 绩效参数
 * 代码描述: 绩效计算参数实体
 * copyright: AUZAR ALL RIGHTS RESERVED
 * company: AUZAR
 *
 * @author: 颜米晨
 * @date: 2022/06/12 0:16
 */
@Data
public class SimulationParam {

    public SimulationParam(BigDecimal contractMoney, BigDecimal contractMoneyHardware,
                           BigDecimal contractMoneySoftware, BigDecimal grossRate, BigDecimal evaluation1,
                           BigDecimal evaluation2, BigDecimal evaluation3, BigDecimal evaluation4) {
        this.contractMoney = contractMoney;
        this.contractMoneyHardware = contractMoneyHardware;
        this.contractMoneySoftware = contractMoneySoftware;
        this.grossRate = grossRate;
        this.evaluation1 = evaluation1;
        this.evaluation2 = evaluation2;
        this.evaluation3 = evaluation3;
        this.evaluation4 = evaluation4;
    }

    /**
     * 绩效参数id
     */
    @NotNull(message = "绩效参数id不能为空")
    private Long performanceConfigId;

    /**
     * 合同额
     */
    @NotNull(message = "合同金额不能为空")
    private BigDecimal contractMoney;

    /**
     * 合同额-硬件部分
     */
    private BigDecimal contractMoneyHardware;

    /**
     * 合同额-软件部分
     */
    private BigDecimal contractMoneySoftware;

    /**
     * 项目毛利率
     */
    @Max(value = 1L, message = "项目毛利率不能超过100%")
    private BigDecimal grossRate;

    /**
     * 评价参数1
     */
    private BigDecimal evaluation1;

    /**
     * 评价参数2
     */
    private BigDecimal evaluation2;

    /**
     * 评价参数3
     */
    private BigDecimal evaluation3;

    /**
     * 评价参数4
     */
    private BigDecimal evaluation4;

}
